<template>
	<div id="teaching" class="i_maxW clear">
		<div class="menuLk fl">
			<el-menu :default-active="activeIndex" @select="handleSelect">
				<template v-for="(item, index) in menuNavRouteData.children">
					<el-menu-item :index="index + ''" v-if="$store.getters.userInfo.is_level == true"
						:class="{ isLink: item.path == 'album' }">
						<i :class="`ipm ${item.icon}`"></i>
						<router-link :to="'/' + menuNavRouteData.path + '/' + item.path + '/' + item.children[0].path"
							:class="{ 'Indexactive': $route.path.split('/')[2] === item.path, 'activePath': isActivePath }">
							{{ item.txtName }}
						</router-link>
						<i class="ipm Shape_04"></i>
					</el-menu-item>
					<el-menu-item :index="index + ''" v-else>
						<i v-if="item.icon === 'jiaoxuezhongxin_icon10'" :class="`${item.icon}`"></i>
						<i v-else :class="`ipm ${item.icon}`"></i>
						<router-link :to="'/' + menuNavRouteData.path + '/' + item.path + '/' + item.children[0].path"
							:class="{ 'Indexactive': $route.path.split('/')[2] === item.path, 'activePath': isActivePath }">
							{{ item.txtName }}
						</router-link>
						<i class="ipm Shape_04"></i>
					</el-menu-item>
				</template>
			</el-menu>
		</div>
		<div class="teaching_cont fr">
			<router-view class="fade-router"></router-view>
		</div>
	</div>
</template>
<script>
export default {
	data() {
		return {
			menuNavRouteData: deep_clone(this.$store.getters.leftMenuNav),
			activeIndex: '1',
			isActivePath: false,
			isLink: false
		}
	},
	watch: {},
	mounted() {

	},
	created() { },
	methods: {
		handleSelect(key, keyPath) {
			// console.log(key, keyPath);
		},
	}
}
</script>
<style lang="scss" scoped>
.jiaoxuezhongxin_icon10 {
	background-image: url('../../assets/images/jxbg_icon.png');
	background-repeat: no-repeat;
	width: 40px;
	height: 40px;
}
</style>